package com.mobimap.nhom9.dao.table;

import android.database.Cursor;

import com.mobimap.nhom9.dto.PlaceTypeDTO;

public class PlaceTypeTable implements IOneKeyTable<PlaceTypeDTO> {
	public static final String[] columns = new String[] { "id", "description",
			"picture" };

	public String getName() {
		return "PlaceType";
	}

	public String[] getColumns() {

		return columns;
	}

	public PlaceTypeDTO cusorToDTO(Cursor cursor) {
		PlaceTypeDTO dto = new PlaceTypeDTO();
		dto.setId(cursor.getInt(0));
		dto.setDescription(cursor.getString(1));
		dto.setPicture(cursor.getString(2));
		return dto;
	}

	public String getColumnKey() {
		return "id";
	}
}
